package cn.netdisk.tinynetdisk.config;

import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Configuration;

import javax.annotation.PreDestroy;

@Configuration
@Slf4j
public class SpringbootShutdownConfig {

    /**
     * springboot应用接收到正常关闭指令执行
     */

    @PreDestroy
    public void shutdownPre() {
        log.info("Execute Finally Tasks Please Wait For Seconds");
        log.info("Finished Shutting Down My Application");
    }
}
